package com.fangsiqi.mashibing;

public class LazyClass {
	private static volatile LazyClass lazyClass;

	private LazyClass(){}

	// DCL Double Check Lock，双重锁验证
	public static synchronized LazyClass getInstance(){
		if(lazyClass==null){
			synchronized (LazyClass.class){
				if(lazyClass==null){
					lazyClass=new LazyClass();
				}
			}
		}
		return lazyClass;
	}
}
